<%--
  Created by IntelliJ IDEA.
  User: 吕天
  Date: 2022/11/29
  Time: 15:45
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>全部员工</title>
    <link rel="stylesheet" href="./layui/css/layui.css">
    <base href="${pageContext.request.scheme }://${pageContext.request.serverName }:${pageContext.request.serverPort }${pageContext.request.contextPath }/ "/>
</head>
<body>
<table class="layui-table">
    <colgroup>
        <col width="150">
        <col width="200">
        <col>
    </colgroup>

    <thead>
    <tr>
        <th>员工编号</th>
        <th>员工姓名</th>
        <th>员工年龄</th>
        <th>员工性别</th>
        <th>操作</th>
    </tr>
    </thead>
    <tbody>
    <c:forEach var="emps" items="${emps}">
        <tr>
            <td>${emps.id}</td>
            <td>${emps.name}</td>
            <td>${emps.age}</td>
            <td>${emps.gender}</td>
            <td>
                    <%--                更新--%>
                <a href="Emp.do?id=${emps.id}&m=selectById">更新</a>
                    <%--                删除--%>
                <a href="javascript:if(confirm('是否确认删除？'))location.href='Emp.do?id=${emps.id}&m=delete'" style="color: red">删除</a>
            </td>
        </tr>

    </c:forEach>

    </tbody>
</table>
<script src="./layui/layui.js"></script>
</body>
</html>
